﻿<%@ Page Title="" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="Facultad.aspx.vb" Inherits="DatosBasicos_Facultad_Default" %>

<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" Runat="Server">
    <style type="text/css">
        .style11
        {
            width: 100%;
            font-size: 0.9em;
            font-family: Arial, Helvetica, "verdana sans-serif";
            border-collapse: collapse;
            text-align: center;
            background-color: #fff;
        }
        .style12
        {
            color: #fff;
            text-align: center;
            text-transform: uppercase;
            height: 25px;
            font-weight: normal;
            border-right: 1px solid #fff;
            padding: 2px;
            background-color: #9CAAC1;
        }
        .style13
        {
            color: #000;
            text-align: center;
            text-transform: uppercase;
            height: 25px;
            font-weight: normal;
            border-right: 1px solid #fff;
            padding: 2px;
            background-color: #DEE1E7;
        }
        .style14
        {
            text-align: center;
        }
        .style15
        {
            width: 207px;
        }
        .style19
        {
            color: #000;
            text-align: center;
            text-transform: uppercase;
            height: 25px;
            font-weight: normal;
            border-right: 1px solid #fff;
            padding: 2px;
            background-color: #DEE1E7;
            width: 25px;
        }
        .style20
        {
            text-align: center;
            width: 25px;
        }
        .style22
        {
            width: 95px;
        }
        .style24
        {
            width: 244px;
        }
        </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" Runat="Server">
    <div class="Cuerpo">
    <asp:Label ID="Label1" runat="server" CssClass="Titulo" 
        Text="Gestión de Facultades"></asp:Label>

    <br />
    <asp:UpdatePanel ID="UpdatePanel1" runat="server">
        <ContentTemplate>
            <asp:MultiView ID="MultiView1" runat="server" ActiveViewIndex="1">
                <asp:View ID="View1" runat="server">
                    <asp:ValidationSummary ID="ValidationSummary1" runat="server" 
                        ValidationGroup="Guardar" CssClass="validacion" />
                        <br />
                        <table class="style11">
                            <thead>
                                <tr>
                                    <td class="style12" colspan="3">
                                        Datos de la facultad</td>
                                </tr>
                            </thead>
                            <thead>
                                <tr>
                                    <th class="style13">
                                        CÓDIGO<th class="style13">
                                            NOMBRE
                                            <th class="style13">
                                                DECANO</th>
                                        </th>
                                    </th>
                                </tr>
                            </thead>
                            <tr>
                                <td class="style14">
                                    <asp:TextBox ID="TxtCod" runat="server" MaxLength="3"></asp:TextBox>
                                    <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" 
                                        ControlToValidate="TxtCod" ErrorMessage="Debe digitar el Codigo" 
                                        ValidationGroup="Guardar">*</asp:RequiredFieldValidator>
                                </td>
                                <td class="style14">
                                    <asp:TextBox ID="TxtNom" runat="server" Width="200px"></asp:TextBox>
                                    <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" 
                                        ControlToValidate="TxtNom" ErrorMessage="debe digitar el nombre" 
                                        ValidationGroup="Guardar">*</asp:RequiredFieldValidator>
                                </td>
                                <td class="style15">
                                    <asp:TextBox ID="TxtDec" runat="server" Width="200px"></asp:TextBox>
                                </td>
                            </tr>
                            <tr>
                                <td class="style14">
                                    &nbsp;</td>
                                <td class="style14">
                                    &nbsp;</td>
                                <td class="style15">
                                    &nbsp;</td>
                            </tr>
                            <tr>
                                <td class="style14">
                                    &nbsp;</td>
                                <td class="style14">
                                    <asp:Button ID="BtnGuardar" runat="server" Text="Guardar" 
                                        ValidationGroup="Guardar" />
                                    <asp:Button ID="BtnEliminar" runat="server" Text="Eliminar" />
                                    <asp:Button ID="BtnCancel" runat="server" Text="Cancelar" />
                                </td>
                                <td class="style15">
                                    &nbsp;</td>
                            </tr>
                    </table>
                </asp:View>
                <asp:View ID="View2" runat="server">
                <br />
                    <table style="width:100%;">
                        <tr>
                            <td class="style22">
                                &nbsp;</td>
                            <td class="style24">
                                &nbsp;</td>
                            <td>
                                &nbsp;</td>
                        </tr>
                        <tr>
                            <td class="style22">
                                Buscar</td>
                            <td class="style24">
                                <asp:TextBox ID="TxtNom0" runat="server" Width="241px"></asp:TextBox>
                            </td>
                            <td>
                                <asp:ImageButton ID="ImageButton1" runat="server" Height="32px" 
                                    ImageUrl="~/Imagenes/search.png" Width="32px" />
                            </td>
                        </tr>
                        <tr>
                            <td class="style22">
                                <asp:LinkButton ID="LinkButton1" runat="server">Nueva facultad</asp:LinkButton>
                            </td>
                            <td class="style24">
                                &nbsp;</td>
                            <td>
                                &nbsp;</td>
                        </tr>
                    </table>
                    <br />
                    <asp:Label ID="Msg" runat="server"></asp:Label>
                    <br />
                    <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" 
                        CellPadding="4" ForeColor="#333333" GridLines="None" Width="527px" 
                        DataKeyNames="Cod_Facultad" DataSourceID="ObjFacultades" SkinID="gridView">
                        <AlternatingRowStyle BackColor="White" ForeColor="#284775" />
                        <Columns>
                            <asp:BoundField DataField="Cod_Facultad" HeaderText="Código" />
                            <asp:BoundField DataField="Nom_Facultad" HeaderText="Nombre de la Facultad" />
                            <asp:BoundField DataField="Decano" HeaderText="Decano de la Facultad" />
                            <asp:ButtonField CommandName="Editar" Text="Editar" />
                            <asp:ButtonField CommandName="Eliminar" Text="Eliminar" />
                        </Columns>
                    </asp:GridView>
                    <asp:ObjectDataSource ID="ObjFacultades" runat="server" 
                        SelectMethod="consultar" TypeName="Facultades">
                        <SelectParameters>
                            <asp:ControlParameter ControlID="TxtNom0" Name="busc" PropertyName="Text" 
                                Type="String" />
                        </SelectParameters>
                    </asp:ObjectDataSource>
                    <asp:HiddenField ID="HfOper" runat="server" />
                    <asp:HiddenField ID="HfPK" runat="server" />
                    <br />
            </asp:View>
            </asp:MultiView>
            
        </ContentTemplate>
    </asp:UpdatePanel>

</div>
    
</asp:Content>

